The present invention relates generally to methods and apparatuses for interfacing with networks, and more particularly to a method and apparatus for interfacing with a network, such as an Ethernet, which permits multiple data rates for traffic on the network.
There are many devices for interfacing with a cable network. One example is a Broadband Telephony Interface (BTI). In the BTI product, as well as many other Broadband Communications products, an Ethernet port is provided for high speed data transfer to and from a personal computer (PC) or the like. The BTI product provides a high-speed connection to the cable plant and multiple telephony ports as well. As the BTI enters its second generation, a 10/100 Base T Ethernet port is standard. This Ethernet port is capable of transmitting and receiving data at 10 Mbps or 100 Mbps speed. Normally, the actual speed is only limited by is peer, i.e., the other device to which it is communicating. For instance, if the BTI is connected to a computer that is equipped with a 10/100 Base T Network card, the two sides will automatically negotiate to use the higher speed. If the computer is equipped with a 10 Base T network card, the two sides will negotiate to use the 10 Mbps that is common to both. The BTI is always enabled for 100 Mbps operation for best performance. The same scenario applied to most other products, including the Surf Board cable modem product line.
From a performance and marketing point of view, it is natural to want to operate the Ethernet port at its maximum speed whenever possible, i.e., as long as the peer supports 100 Mbps, for example. However, operating the Ethernet port in 100 Mbps mode requires significantly more power, thereby decreasing a length of time the device can be powered by batteries, and concomitantly decreasing the number and types of applications to which these products may be applied. Furthermore, as energy costs continue to rise and energy sources remain constant, pressure builds to reduce and conserve energy. Moreover, as networks have become ubiquitous in today""s society, these devices will become potentially significant consumers of energy.
The present invention is therefore directed to the problem of developing a method and apparatus for reducing the power consumed by network interface devices without sacrificing performance in the communications process.
The present invention solves these and other problems by providing a method and apparatus for controlling the operating speed of the interface so that it operates at a minimum power consuming speed, except when transmitting data.
According to an exemplary embodiment of a method for controlling an interface between a processor and a network, the embodiment monitors data traffic from both a processor side and a network side. Upon detecting a predetermined period of no data traffic on both sides, the embodiment disables an auto-negotiation mode of the interface, and forces the interface to operate at its lowest speed. Alternatively, the embodiment may force the interface to auto-negotiate a lower speed by not advertising its high-speed capability. The embodiment may also briefly remove a link signal to allow a peer to adapt to a new speed prior to changing speed.
Once in the low speed mode, the embodiment monitors data on both the processor side and the network side. Upon detecting a predetermined and configurable amount of data, the embodiment enables the auto-negotiate mode. Again, prior to switching speeds, the embodiment may briefly removes a link signal to allow a peer to adapt to a new speed. Hysteresis may also be included in the embodiment to prevent a speed change if a predetermined period has not occurred since a last speed change.
According to another embodiment of a method for controlling an interface between a processor and a network, the embodiment monitors data traffic from both a processor side and a network side, and upon detecting a predetermined period of no data traffic on both sides, forces the interface to operate at its lowest speed. According to this embodiment, the speed is switched without disabling the auto-negotiation mode. One technique for switching without disabling the auto-negotiation mode includes forcing an Ethernet controller to advertise a specific speed and forcing a re-auto-negotiation.
According to another embodiment of a method for controlling a communications interface, the embodiment monitors a counter on an input side of the communications interface and monitors a counter on an output side of the communications interface. The embodiment switches to a lower speed mode if detected activity lies below a first threshold for a first predetermined period in both the input and output counters, and switches to a higher speed mode if detected activity in either one of the input and output counters exceeds a predetermined threshold for a second predetermined period. This embodiment can be applied to a communications interface that utilizes multiple speed modes. In the multiple speed mode application, switching to a lower speed mode operates by switching to a next lower speed mode of the multiple speed modes if not already in a lowest speed mode, and switching to a higher speed mode operates by switching to a next higher speed mode if not already in a highest speed mode.
According to another aspect of the present invention, an apparatus for performing the above methods includes a process, memory, a network interface and input an output counters. The memory stores instructions for execution by the processor. The network interface is coupled to an input and output data line and provides incoming and outgoing data signals. The input counter counts a number of incoming data packets and the output counter counts a number of outgoing data packets. The processor is coupled to the memory, the network interface, the input and output counters, and executes the instructions stored in the memory, and increments the input and output counters based on data packets present in said incoming and outgoing data signals, respectively, from the network interface. The processor further switches to a lower speed mode if detected activity lies below a first threshold for a first predetermined period in both the input and output counters and switches to a higher speed mode if detected activity in either one of the input and output counters exceeds a second predetermined threshold for a second predetermined period.
According to another aspect of the present invention, a computer readable media includes programming instructions encoded thereon causing a processor to monitor a counter on an input side of the communications interface and monitor a counter on an output side of the communications interface, and switch to a lower speed mode if detected activity lies below a first threshold for a first predetermined period in both the input and output counters, and switch to a higher speed mode if detected activity in either one of the input and output counters exceeds a second predetermined threshold for a second predetermined period.